package org.manager.units;

import java.io.Serializable;
import java.util.Date;
import java.util.HashSet;
import java.util.Set;

import org.manager.authorize.UserAccount;

/**
 * 单位表
 * @author zxf_noimp
 *
 */
public class SysUnits implements Serializable {
    private static final long serialVersionUID = 3257568390917667121L;
    private String id;  //编号
	private String code;   //业务代码
    private String unitCode;  //单位代码
    private String unitName;  //单位名称
    private String unitParentCode; //父单位代码
    private String unitParentId;
    private Integer unitLevel;  //单位级别
    private String unitAddress; //单位地址
    private String unitMobile;  //电话   
    private String unitFax;  //传真
    private String unitRemark;  //备注 
    private Integer unitOrder;  //单位排序编码
    private String unitControl;  //单位特殊业务控制（如，在前台提取单位时，控制某些单位不显示）
    private Date unitDate;  //单位创建时间
    private String masterId;  //操作员编号
    private String masterName;  //操作员名称  
    private String subCode;  //所属应用
    private int propertiesCount ; 
    private String parentUnitName; 
    
    private Set<ClassHours> classHoursSet = new HashSet<ClassHours>();
    private Set<UserAccount> userSet = new HashSet<UserAccount>();
    
    public SysUnits(){
    }
    
    public void addUser(UserAccount user){
    	userSet.add(user);
    }

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}

	public String getUnitCode() {
		return unitCode;
	}

	public void setUnitCode(String unitCode) {
		this.unitCode = unitCode;
	}

	public String getUnitName() {
		return unitName;
	}

	public void setUnitName(String unitName) {
		this.unitName = unitName;
	}

	public String getUnitParentCode() {
		return unitParentCode;
	}

	public void setUnitParentCode(String unitParentCode) {
		this.unitParentCode = unitParentCode;
	}

	public Integer getUnitLevel() {
		return unitLevel;
	}

	public void setUnitLevel(Integer unitLevel) {
		this.unitLevel = unitLevel;
	}

	public String getUnitAddress() {
		return unitAddress;
	}

	public void setUnitAddress(String unitAddress) {
		this.unitAddress = unitAddress;
	}

	public String getUnitMobile() {
		return unitMobile;
	}

	public void setUnitMobile(String unitMobile) {
		this.unitMobile = unitMobile;
	}

	public String getUnitFax() {
		return unitFax;
	}

	public void setUnitFax(String unitFax) {
		this.unitFax = unitFax;
	}

	public String getUnitRemark() {
		return unitRemark;
	}

	public void setUnitRemark(String unitRemark) {
		this.unitRemark = unitRemark;
	}

	public Integer getUnitOrder() {
		return unitOrder;
	}

	public void setUnitOrder(Integer unitOrder) {
		this.unitOrder = unitOrder;
	}

	public String getUnitControl() {
		return unitControl;
	}

	public void setUnitControl(String unitControl) {
		this.unitControl = unitControl;
	}

	public Date getUnitDate() {
		return unitDate;
	}

	public void setUnitDate(Date unitDate) {
		this.unitDate = unitDate;
	}

	public String getMasterId() {
		return masterId;
	}

	public void setMasterId(String masterId) {
		this.masterId = masterId;
	}

	public String getMasterName() {
		return masterName;
	}

	public void setMasterName(String masterName) {
		this.masterName = masterName;
	}

	public String getSubCode() {
		return subCode;
	}

	public void setSubCode(String subCode) {
		this.subCode = subCode;
	}

	public Set<ClassHours> getClassHoursSet() {
		return classHoursSet;
	}

	public void setClassHoursSet(Set<ClassHours> classHoursSet) {
		this.classHoursSet = classHoursSet;
	}

	public static long getSerialVersionUID() {
		return serialVersionUID;
	}

	public int getPropertiesCount() {
		return propertiesCount;
	}

	public void setPropertiesCount(int propertiesCount) {
		this.propertiesCount = propertiesCount;
	}

	public String getParentUnitName() {
		return parentUnitName;
	}

	public void setParentUnitName(String parentUnitName) {
		this.parentUnitName = parentUnitName;
	}

	public String getUnitParentId() {
		return unitParentId;
	}

	public void setUnitParentId(String unitParentId) {
		this.unitParentId = unitParentId;
	}
	
	public void setUserSet(Set<UserAccount> userSet) {
		this.userSet = userSet;
	}
	
	public Set<UserAccount> getUserSet() {
		return userSet;
	}

}
